#![allow(unused)]
//! 状态码模块
//! 为了适应国际化，所有返回的消息都要有一一对应的状态码，前端统一进行状态码的国际化提示

/// 成功
pub const OK: (u16, &str) = (0, "OK");
/// 参数错误
pub const PARAM_ERROR: (u16, &str) = (4000, "请求参数错误");
/// 鉴权失败
pub const AUTH_ERROR: (u16, &str) = (4001, "鉴权失败");
/// 验证码错误
pub const CODE_ERROR: (u16, &str) = (4002, "验证码错误");
/// 验证码已过期
pub const CODE_EXPIRE: (u16, &str) = (4003, "验证码已过期");
/// 邮箱已被注册
pub const EMAIL_REGISTERED: (u16, &str) = (4004, "邮箱已被注册");
/// 账号或密码错误
pub const EMAIL_PWD_ERROR: (u16, &str) = (4005, "账号或密码错误");
/// 账号不存在
pub const EMAIL_NOT_EXIST: (u16, &str) = (4006, "账号不存在");
/// 设备已被注册
pub const DEVICE_REGISTERED: (u16, &str) = (4007, "设备已被注册");
/// 用户权限不足
pub const PERMISSION_DENIED: (u16, &str) = (4008, "用户权限不足");

/// 内部错误
pub const INTERNAL_ERROR: (u16, &str) = (5000, "内部错误");
